[IA64] fix paging_init()
authorawilliam@xenbuild.aw <awilliam@xenbuild.aw>
Wed, 5 Apr 2006 18:17:44 +0000 (12:17 -0600)
committerawilliam@xenbuild.aw <awilliam@xenbuild.aw>
Wed, 5 Apr 2006 18:17:44 +0000 (12:17 -0600)
fix paginig_init() to initialize mpt_table properly.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
G: manifest hash ca7d4ed1b47fcd1f85fbf0005c810796b1f0c6cb

xen/arch/ia64/xen/xenmem.c

index 6489bdc2b1771edff6012385797ba090e9918617..7be1e0eec07bd60cead10fa94630fb26b6f364a3 100644 (file)
@@ -47,8 +47,12 @@ paging_init (void)
        if ((mpt_table = alloc_xenheap_pages(mpt_order)) == NULL)
                panic("Not enough memory to bootstrap Xen.\n");
 
-       printk("machine to physical table: 0x%lx\n", (u64)mpt_table);
-       for (i = 0; i < (1UL << mpt_order); i++) {
+       printk("machine to physical table: 0x%lx mpt_table_size 0x%lx\n"
+              "mpt_order %u max_page 0x%lx\n",
+              (u64)mpt_table, mpt_table_size, mpt_order, max_page);
+       for (i = 0;
+            i < ((1UL << mpt_order) << PAGE_SHIFT) / sizeof(mpt_table[0]);
+            i++) {
                mpt_table[i] = INVALID_M2P_ENTRY;
        }
 }